﻿using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ProgramCat.FiddlerExtension.Core.Utils
{
    /// <summary>
    /// 颜色帮助类
    /// </summary>
    public static class ColorHelper
    {
        /// <summary>
        /// 整数颜色到Color结构
        /// </summary>
        /// <param name="rgb"></param>
        /// <returns></returns>
        public static Color IntToColor(int rgb)
        {
            return Color.FromArgb(255, (byte)(rgb >> 16), (byte)(rgb >> 8), (byte)rgb);
        }
        
    }
}
